import React, { Component } from 'react';
import {connect} from './react-redux/index';
import * as actions from './react-redux/actions';
class PPa extends Component {
    constructor(props) {
        super(props);
        this.state = {  };
    }
    render() {
        const {num,add}=this.props;
        return (
            <>
            <h1>PPa</h1>
            <hr/>
            <p>{num}</p>
            <button onClick={add}>点击添加</button>
            </>
        );
    }
}
function mapstate(state){
    return state;
}

export default connect(mapstate,actions)(PPa);